@import '../../common.less';

/**
 * 扫描记录表格组件样式
 */

.report-record-table {
    .filter-bar {
        .sa-filter-bar();
    }

    .ant-table-wrapper {
        .sa-table-wrapper();
    }

    // 文件名列特殊样式
    .ant-table-tbody > tr > td {
        &[data-index="fileName"] {
            font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace;
            font-size: 12px;
            color: #595959;
            background-color: #fafafa;
        }
    }

    // 应用ID列样式
    .ant-table-tbody > tr > td {
        &[data-index="appId"] {
            font-weight: 500;
            color: #262626;
        }
    }

    // 记录数量列样式
    .ant-table-tbody > tr > td {
        &[data-index="recordCount"] {
            font-weight: 500;
            font-variant-numeric: tabular-nums;
        }
    }

    // IP地址列样式
    .ant-table-tbody > tr > td {
        &[data-index="ip"] {
            font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace;
            color: #595959;
        }
    }

    // 扫描日期列样式
    .ant-table-tbody > tr > td {
        &[data-index="scanDate"] {
            color: #595959;
            font-variant-numeric: tabular-nums;
        }
    }

    // 单元ID链接按钮样式增强
    .ant-btn-link {
        font-weight: 500;
        transition: all 0.2s ease;

        &:hover {
            color: #40a9ff;
            text-decoration: underline;
            transform: translateX(2px);
        }

        &:active {
            color: #096dd9;
        }
    }

    // 空状态图标样式
    .ant-empty {
        .ant-empty-image {
            height: 80px;
            margin-bottom: 16px;
        }
    }

    // 响应式调整
    @media (max-width: 1200px) {
        .ant-table-wrapper {
            .ant-table-tbody > tr > td,
            .ant-table-thead > tr > th {
                &[data-index="fileName"] {
                    max-width: 200px;
                }
            }
        }
    }

    @media (max-width: 768px) {
        .filter-bar {
            .ant-input {
                width: 100% !important;
            }
        }

        .ant-table-wrapper {
            .ant-table-tbody > tr > td,
            .ant-table-thead > tr > th {
                padding: 12px 8px !important;
                font-size: 12px;

                &[data-index="fileName"] {
                    max-width: 150px;
                }
            }
        }
    }
}
